package com.hissagetest;

import android.view.ViewGroup;

public class HelloLayoutSettingData {
	private static HelloLayoutSettingData singleton ;
	private SettingData data[];
	
	static public class SettingData {
		public int type ;
		public int weight ;
	}
	
	private HelloLayoutSettingData() {
		
		data = new SettingData[4] ;
		for (int i = 0; i < data.length; i++) {
			data[i]        = new SettingData() ;
			data[i].type   = ViewGroup.LayoutParams.WRAP_CONTENT ;
			data[i].weight = 1 ;
		}
	}
	
	public static SettingData GetData(int index) {
		if (singleton == null) 
			singleton = new HelloLayoutSettingData() ;
		
		return singleton.data[index] ;
	} ;
	
	public static void SetData(int index, SettingData data) {
		if (singleton == null) 
			singleton = new HelloLayoutSettingData() ;
		
		singleton.data[index] = data ;
	} ;	
}
